import Vue from 'vue'
import Vuex from 'vuex'
import creatLogger from 'vuex/dist/logger'

Vue.use(Vuex)

import UserInfo from './userInfo'
import Breadcrubms from './breadcrubms'
import Shop from './shop'
import Address from './address'
import Jmessage from './jmessage'

const debug = process.env.NODE_ENV !== 'production'

export default new Vuex.Store({
  modules: {
    UserInfo,
    Breadcrubms,
    Shop,
    Address,
    Jmessage
  },
  plugins: debug ? [creatLogger()] : []
})
